package com.tfjybj.itoo.exam.model;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.tfjybj.itoo.exam.entity.ClassEntity;
import com.tfjybj.itoo.exam.entity.ExaminationEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.ToString;
import lombok.experimental.Accessors;

import javax.persistence.Column;
import java.io.Serializable;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;

/**
 * ExaminationModel
 * 考试表
 *
 * @author 任晓帅 
 * @version 2.0.0
 * @since 2.0.0 2018-11-15 19:40:28
 */
@ApiModel(value = "ExaminationModel:考试表")
@Data
@NoArgsConstructor
@Accessors(chain = true)
@ToString(callSuper = true)
public class ExaminationModel  implements  Serializable {

    //region 模板逆向生产来自ExaminationEntity的属性
	/**
	 * id
	 */
	@ApiModelProperty(value = "examination主键")
	@Column(name = "id")
	private String id;
   	/**
	 * 课程id
	 */
	@ApiModelProperty(value = "课程id",required = true)
	private String courseId;

	/**
	 * 考试名称
	 */
	@ApiModelProperty(value = "考试名称",required = true)
	private String examName;

	/**
	 * 总分 operator
	 */
    @ApiModelProperty(value = "总分")
	private String score;

	/**
	 * 操作人
	 */
	@ApiModelProperty(value = "操作人")
	private String operator;

	/**
	 * 考试分类id
	 */
	@ApiModelProperty(value = "考试分类id",required = true)
	private String classifyId;

	@ApiModelProperty(value="分类名字")
	private String classifyName;
	/**
	 * 模板id
	 */
	@ApiModelProperty(value = "模板id",required = true)
	private String templateId;

	/**
	 * 开始时间
	 */
	@JsonFormat(
        pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8"
    )
	@ApiModelProperty(value = "开始时间",required = true)
	private Date startTime;

	/**
	 * 结束时间
	 */
	@JsonFormat(
        pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8"
    )
	@ApiModelProperty(value = "结束时间",required = true)
	private Date endTime;

	/**
	 * 模板类型（1选题组卷，2抽题组卷，3随机组卷）
	 */
	@ApiModelProperty(value = "模板类型（0选题组卷，1抽题组卷，2随机组卷）",required = true, example = "0")
	private Integer templateType;

	/**
	 * 模板类型
	 */
	@ApiModelProperty(value = "模板类型（选题组卷-0，抽题组卷-1，随机组卷-2）",required = true, example = "0")
	private Integer templateTypeName;

	/**
	 * 总题数
	 */
    @ApiModelProperty(value = "总题数", example = "0")
		private Integer topicSum;

	/**
	 * 状态 {默认（未使用）：0，正在使用 1，已使用 2}
	 */
	@ApiModelProperty(value = "状态 {默认（未使用）：0，正在使用 1，已使用 2}",required = true, example = "0")
	private Integer state;

	/**
	 * 判分状态 {未判分-2 , 已判分-3}
	 */
	@ApiModelProperty(value = "判分状态 {未判分-2 , 已判分-3}",required = true)
	private String scoreState;
	/**
	 * 期望分值
	 */
    @ApiModelProperty(value = "期望分值", example = "0")
	private Integer expectValue;

	/**
	 * 考试时长
	 */
	@ApiModelProperty(value = "考试时长",required = true, example = "0")
	private Integer examDuration;

	/**
	 * 是否安排考生须知(0安排 1不安排)
	 */
    @ApiModelProperty(value = "是否安排考生须知(0安排 1不安排)", example = "0")
	private Integer isStudentNotes;

	/**
	 * 考生须知id
	 */
    @ApiModelProperty(value = "考生须知id")
	private String studentNotesId;

	/**
	 * 须知时长
	 */
    @ApiModelProperty(value = "须知时长", example = "0")
	private Integer readTime;

	/**
	 * 历史id
	 */
    @ApiModelProperty(value = "历史id")
	private String historyId;

	/**
	 * 版本（默认为1，以后是2，3，4....）
	 */
    @ApiModelProperty(value = "版本（默认为1，以后是2，3，4....）", example = "0")
	private Integer version;

	/**
	 * 资源表id
	 */
    @ApiModelProperty(value = "资源表id")
	private String datumId;

	/**
	 * 是否安排调查问卷(0不安排 1安排)
	 */
    @ApiModelProperty(value = "是否安排调查问卷(0不安排 1安排)", example = "0")
	private Integer isEvaluation;

	/**
	 * 问卷id
	 */
	@ApiModelProperty(value = "问卷id")
	private String evaluationPaperId;
	//endregion

     /* *****************************以下是非模板生成的内容************************************ */
     @ApiModelProperty(value = "创建者id")
	private String operatorId;

    @ApiModelProperty(value="学生id")
	private String studentId;

	/**
	 * 问卷名称
	 */
	@ApiModelProperty(value = "问卷名称")
	private String evaluationPaperName;

	/**
	 * 理论交卷日期时间
	 */
	@JsonFormat(
			pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8"
	)
	@ApiModelProperty(value = "理论交卷日期时间")
	private Date shouldSubmitTime;
	/**
	 * 课程名称
	 */

	@ApiModelProperty(value = "课程名称")
	private String courseName;

	@ApiModelProperty(value="学号")
	private String studentCode;

	@ApiModelProperty(value="考生姓名")
	private  String studentName;
	@ApiModelProperty(value="考生id")
	private  String examineeId;
	@ApiModelProperty(value="班级名称")
	private String className;


	@ApiModelProperty(value="成绩")
	private String studentScore;


	@ApiModelProperty(value="班级Id")
	private String classId;


	@ApiModelProperty(value="发送邮件")
	private String sendMail;

	@ApiModelProperty(value="考试ID")
	private String examId;

	@ApiModelProperty(value="分类父id")
	private String parentId;

	@ApiModelProperty(value="是否为叶子结点")
	private  String isLeaf;

	@ApiModelProperty(value="学生姓名")
	private  String stuName;

	@ApiModelProperty(value="考生id")
	private String examineId;

	@ApiModelProperty(value="状态")
	private String status;

	@ApiModelProperty(value = "删除", example = "0")
	private Integer  isdelete;

	@ApiModelProperty(value="应到人id", example = "0")
	private  Integer  paperExamineId;

	@ApiModelProperty(value="实到人id", example = "0")
	private  Integer scoreExamineId;


	@ApiModelProperty(value="获得成绩人数", example = "0")
	private Integer sumNumber;

	@ApiModelProperty(value="班级实体")
	private List<ClassEntity> classEntities;

	@ApiModelProperty(value="考试实体")
	private List<ExaminationEntity> examEntities;

	@ApiModelProperty(value="每道小题满分", example = "0")
	private Integer standScore;

	@ApiModelProperty(value="章节id")
	private String chapterId;

	@ApiModelProperty(value="章节名称")
	private String chapterName;
	@ApiModelProperty(value="章节总分")
	private int  chapterNum;
	@ApiModelProperty(value="学生章节得分")
	private int  chapterScore;
	//学生章节应得总分
	@ApiModelProperty(value="学生章节应得总分")
	private int  studentChapterNum;
	//学生章节得分百分比
	@ApiModelProperty(value="学生章节得分百分比")
	private int  percent;

	/**
	 * 子类
	 */
	public List<ExaminationscoreModel> ExaminationScoreModelList = new ArrayList<>();


}
